Skip to content

[pull] main from python:main - #1659

Merged
pull[bot] merged 9 commits into
All-Blockchains:mainfrom
python:main
Sep 2, 2026
Merged

[pull] main from python:main#1659
pull[bot] merged 9 commits into
All-Blockchains:mainfrom
python:main

Conversation

@pull

@pull pull Bot commented Sep 2, 2026

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

serhiy-storchaka and others added 9 commits September 2, 2026 15:30
…GH-156659)

XML defines white space as " \t\r\n" (see XML 1.0, 2.3), but str.strip()
also strips other characters, such as U+00A0.  Such characters could be
lost in ElementTree.indent(), in canonicalize(strip_text=True), and when
parsing with the whitespace-in-element-content feature turned off.
Co-authored-by: Tim Hoffmann <2836374+timhoffm@users.noreply.github.com>
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
…54884)

Co-authored-by: Blaise Pabon <blaise@gmail.com>
Co-authored-by: Stan Ulbrych <stan@python.org>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Replace soft deprecated PyBytes_FromStringAndSize() with
PyBytesWriter.
Corrected:

* the name of the errorHandler argument of parse() and parseString();
* the default value of the parser_list argument of make_parser();
* the description of the source of parse();
* the types of the declaration-handler and dom-node properties;
* the way in which names are interned;
* the description of IncrementalParser.

Documented:

* default_parser_list and SAXReaderNotAvailable;
* property_encoding and property_interning_dict;
* IncrementalParser.prepareParser();
* XMLFilterBase.getParent() and setParent();
* which features and properties the parser based on Expat does not support.

Added missing docstrings to parse(), parseString(), AttributesImpl and
XMLGenerator.
…156840)

Corrected:

* the node types for the PROCESSING_INSTRUCTION and COMMENT events;
* the return value of getEvent() at the end of the document;
* the type of the argument of parseString();
* references to the xml.dom interfaces, written as xml.dom.minidom.

Documented:

* the event constants, which were referenced but never described;
* PullDOM, SAX2DOM and the documentFactory argument;
* the arguments of DOMEventStream, its reset() and clear() methods.

Added docstrings to the module, the classes and their public methods, and
removed the commented out paragraph about pulldom in the xml.dom
documentation, which was never rendered and refers to a site which no longer
exists.
Corrected:

* the parser argument of iterparse() is an instance of XMLParser or its
  subclass, not a subclass;
* feed() accepts a string as well as encoded data;
* keys() and items() do not return a list in the Python implementation, and
  the attributes are no longer returned in an arbitrary order.

Removed the claims that the element tag, the attribute names and values, the
text of a comment and the data of TreeBuilder.data() can be bytes.  It is a
Python 2 leftover.  Documented instead what they can be.
@pull pull Bot locked and limited conversation to collaborators Sep 2, 2026
@pull pull Bot added the ⤵️ pull label Sep 2, 2026
@pull
pull Bot merged commit 09ff4d4 into All-Blockchains:main Sep 2, 2026
2 of 4 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants